/* 将年月日处理成时间戳 */
let passToStartDate = function(value){
  var d = new Date(value);
  var datetime=d.getFullYear() + '-' + (d.getMonth() + 1) + '-' + d.getDate() + ' ' + d.getHours() + ':' + d.getMinutes() + ':' + d.getSeconds();
  return datetime
}
let passToEndDate = function(value){
  var d = new Date(value);
  var datetime=d.getFullYear() + '-' + (d.getMonth() + 1) + '-' + d.getDate() + ' ' + ' 23:59:59';
  return datetime
}
function isvalidPhone(str) {
  const reg = /^1[3|4|5|7|8][0-9]\d{8}$/
  return reg.test(str)
}
export default {
  passToStartDate,
  passToEndDate,
  isvalidPhone
 
};